#ifndef DISPLAY_DATA_H
#define DISPLAY_DATA_H

#include <QAbstractItemModel>

class display_data : public QAbstractItemModel
{
    Q_OBJECT

public:
    explicit display_data(QObject *parent = nullptr);

    // Header:
    QVariant headerData(int section, Qt::Orientation orientation, int role = Qt::DisplayRole) const override;

    // Basic functionality:
    QModelIndex index(int row, int column,
                      const QModelIndex &parent = QModelIndex()) const override;
    QModelIndex parent(const QModelIndex &index) const override;

    int rowCount(const QModelIndex &parent = QModelIndex()) const override;
    int columnCount(const QModelIndex &parent = QModelIndex()) const override;

    QVariant data(const QModelIndex &index, int role = Qt::DisplayRole) const override;

    static void send_slots(QString);

    static display_data * m_display;

    int postMessageCommand(QString);

signals:
    void read_data_send(QString mmp);
private:
};

#endif // DISPLAY_DATA_H
